<link rel="stylesheet" href="__JS__/fancybox/source/jquery.fancybox.css?v=2.1.4" type="text/css" media="screen" />
<script type="text/javascript" src="__JS__/fancybox/source/jquery.fancybox.pack.js?v=2.1.4"></script>
<script type="text/javascript">
	$(document).ready(function() {
		$(".fancybox").fancybox();
		$('.selected_attr').each(function(){
			var id = $(this).attr('title');
			var name = $('#attr_'+id).html();
			var group = $('#attr_'+id).parent().parent().parent().find('span').html();
			var identify = $('#attr_'+id).attr('title');
			var html = '<font alt="'+identify+'" title="'+id+'" class="group_select">'+group+'</font>'+name+'<font class="remove"></font>';
			$(this).html(html);
		});
		$('.remove').live('click',function(){
			$(this).parent().remove();
			var url = '';
			$('.group_select').each(function(){
				url += $(this).attr('alt')+'/'+$(this).attr('title')+'/';
			});

			window.location.href=TP_URL+'/index/'+url;
		});
	});
</script>
<h2 class="page-title" style="margin-bottom:0;">產品介紹</h2>
<div class="product-content">
	<div class="attribute">
		<if condition="$selected">
		<ul class="selected_box">
			<li><span>已選擇：</span>
				<div class="attr_box">
					<volist name="selected" id="select">
						<div class="selected_attr" id="selected-{$select}" title="{$select}"></div>
					</volist>
				</div>
			</li>
		</ul>
	</if>
		<volist id="attritube" name="attritubes">
		<ul>
				<li><span>{$attritube.group_name}:</span>
					<div class="attr">
						<volist name="attritube.attritubes" id="attr">
							<a href="__URL__/index/year/
							<if condition="$attritube.identify neq 'year'">
								<if condition="$year">{$year}<else />0</if>
							<else />
							{$attr.attritube_id}
							</if>
							/style/
							<if condition="$attritube.identify neq 'style'">
								<if condition="$style">{$style}<else />0</if>
							<else />
							{$attr.attritube_id}
							</if>
							/mate/
							<if condition="$attritube.identify neq 'mate'">
								<if condition="$mate">{$mate}<else />0</if>
							<else />
							{$attr.attritube_id}
							</if>
							"><font id="attr_{$attr.attritube_id}" title="{$attritube.identify}">{$attr.attritube_name}</font>({$attr.total|showZero})</a>
					    </volist>
					</div>
				</li>
		</ul>
		<div class="clear"></div>
		</volist>

	</div>
	<div class="production">
		<volist name="rows" id="row" key="k" mod="3">
			<if condition="($k eq 0) or ($mod eq 0)">
            <ul class="thumbnails">
            </if>
                <li class="<if condition="($k eq 0) or ($mod eq 0)">first</if><if condition="($k eq $count) or ($mod eq 2)">last</if>">
                	<a class="fancybox" rel="gallery1" href="__IMAGES__/c1.jpg">
                		<img src="{$row.thumb|getProductImage}" />
                		<p>{$row.name}</p>
                	</a>
                </li>
            <if condition="($k eq $count) or ($mod eq 2)">
            </ul>
            </if>
		</volist>
	</div>
	<div class="clear"></div>
    <div class="pages">{$page}</div>
</div>